package com.test.web.dao;

import com.test.web.bean.vue.sort.SortBean;
import com.test.web.entity.Role;
import org.apache.ibatis.annotations.Param;

import java.util.Collection;
import java.util.List;

/**
 * @author heyanjing
 * date:2020-07-03 2020/7/3:9:57
 */
public interface RoleDao {

    int deleteByPrimaryKey(String roleId);

    int insert(Role record);

    int insertOrUpdate(Role record);

    int insertOrUpdateSelective(Role record);

    int insertSelective(Role record);

    Role selectByPrimaryKey(String roleId);

    int updateByPrimaryKeySelective(Role record);

    int updateByPrimaryKey(Role record);

    int updateBatch(List<Role> list);

    int batchInsert(@Param("list") List<Role> list);

    List<Role> findByRoleNameLike(@Param("likeRoleName") String likeRoleName, @Param("state") String state, @Param("sortList") List<SortBean> sortList);

    int updateStateByRoleIdIn(@Param("updatedState") String updatedState, @Param("roleIdCollection") Collection<String> roleIdCollection);

}